<template>
	<view class="goodsListBox">
		<view class="goodsListInnier">
			<view class="GoodListTitle">{{name}}</view>
			<view class="goodsBox">
				<view class="goodsItem" v-for="item in list" :key="item.id">
					<image :src="item.list_pic_url" class="goodImg" mode="widthFix"></image>
					<view class="goodname">{{item.name}}</view>
					<view style="color:#8b0000;height: 80rpx;line-height: 80rpx;"> ￥
						{{ item.retail_price | handelPrice}} 元
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		props: {
			list: {
				type: Array,
				default: []
			},
			name: {
				type: String,
				default: ""
			}
		}
	}
</script>

<style>
	.goodsListBox {
		width: 100%;
		height: auto;
		background-color: #fff;
		font-family: "黑体";
	}

	.goodsListInnier {
		width: 100%;
		padding-top: 36rpx;
	}

	.GoodListTitle {
		width: 100%;
		line-height: 100rpx;
		text-align: center;
		font-size: 40rpx;
		color: #333333;

	}

	.goodsBox {
		width: 100%;
		display: flex;
		flex-wrap: wrap;
	}

	.goodsItem {
		width: calc(50vw);
		font-size: 28rpx;
		text-align: center;
	}

	.goodname {
		overflow: hidden;
		white-space: nowrap;
		text-overflow: ellipsis;
	}

	.goodImg {
		width: calc(50vw);
		height: 368rpx;
	}
</style>
